package com.hltx.controller.brokerage;

import java.math.BigDecimal;

import javax.servlet.http.HttpSession;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

import com.hltx.controller.base.BaseController;
import com.hltx.pojo.user.User;
import com.hltx.service.brokerage.impl.ConsumeBrokerageService;
import com.hltx.service.brokerage.impl.ConsumeBrokerageV2Service;

@Controller
@RequestMapping( value ="cb")
public class ConsumeBrokerageController extends BaseController {
	
	@Autowired
	private ConsumeBrokerageService brokerageService;
	@Autowired
	private ConsumeBrokerageV2Service brokerageV2Service; 
	
	@RequestMapping(value="brokerage")
	public ModelAndView brokerage(HttpSession session){
		ModelAndView view =this.getModelAndView();
		User user =(User) session.getAttribute("sessionUser");	
		brokerageService.bonusTask(user, new BigDecimal(10));
		brokerageV2Service.bounsShunt(new Long("订单ＩＤ"));
		view.setViewName("error");
		return view;
	}

}
